/*
 * Copyright (c) 2024 Black Sesame Technologies
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef _DAL_UTILS_H_
#define _DAL_UTILS_H_

#ifdef __cplusplus
extern "C" {
#endif

typedef struct dal_utils_allocator_s
{
    void* (*allocate)(size_t size);
    void (*deallocate)(void* pointer);
    void* (*reallocate)(void* pointer, size_t size);
    void* (*zero_allocate)(size_t number_of_elements, size_t size_of_element);
} dal_utils_allocator_t;

dal_utils_allocator_t dal_utils_get_allocator(void);

#ifdef __cplusplus
}
#endif

#endif  // _DAL_UTILS_H_
